import { http } from "@/utils/http";

type ListResult = {
  msg: string;
  code: any;
  message: string;
  list: Array<any>;
};

export function getListApi(params?: object): Promise<ListResult> {
  return http.request({
    url: "/list/get",
    method: "get",
    params
  });
}
export function ShowNotice(): Promise<ListResult> {
  return http.request({
    url: "/User/ShowNotice",
    method: "post",
  });
}
export function PayChannelList(): Promise<ListResult> {
  return http.request({
    url: "/Payment/PayChannelList",
    method: "post",
  });
}

export function getListApiError(data?: object): Promise<ListResult> {
  return http.request({
    url: "/list/error",
    method: "post",
    data
  });
}
export function UserEnroll(data?: object) {
  return http.request({
    url: "/UserLogin/UserEnroll",
    method: "post",
    data
  });
}
export function UserLogin(data?: object) {
  return http.request({
    url: "/UserLogin/UserLogin",
    method: "post",
    data
  });
}
export function UserWallet(data?: object) {
  return http.request({
    url: "/User/UserWallet",
    method: "post",
    data
  });
}
export function FeedbackUploadImage(data?: object) {
  return http.request({
    url: "/Feedback/FeedbackUploadImage",
    method: "post",
    data
  });
}
export function AddFeedback(data?: object) {
  return http.request({
    url: "/Feedback/AddFeedback",
    method: "post",
    data
  });
}
export function FeedbackList(data?: object) {
  return http.request({
    url: "/Feedback/FeedbackList",
    method: "post",
    data
  });
}
export function UserRecommendList(data?: object) {
  return http.request({
    url: "/MatchRecord/UserRecommendList",
    method: "post",
    data
  });
}
export function StartPayment(data?: object) {
  return http.request({
    url: "/Payment/StartPayment",
    method: "post",
    data
  });
}
export function UserExpend(data?: object) {
  return http.request({
    url: "/User/UserExpend",
    method: "post",
    data
  });
}
export function CreateUser(data?: object) {
  return http.request({
    url: "/WyYunxin/createUser",
    method: "post",
    data
  });
}
export function GetUserMuteTime(data?: object) {
  return http.request({
    url: "/WyYunxin/getUserMuteTime",
    method: "post",
    data
  });
}

export function EmptyUserName(data?: object) {
  return http.request({
    url: "/WyYunxin/emptyUserName",
    method: "post",
    data
  });
}
export function UpdateUser(data?: object) {
  return http.request({
    url: "/WyYunxin/updateUser",
    method: "post",
    data
  });
}

export function IndexNotice(data?: object) {
  return http.request({
    url: "/UserLogin/IndexNotice",
    method: "get",
    data
  });
}

